{% include 'front/header.html' %}
		<link rel="stylesheet" href="/resource/front/css/login.css" />
	</head>
	<body>
		<div class="user-con">
			<header class="mui-bar mui-bar-nav">
				<a class="mui-action-back">
					<img src="/resource/front/img/图层9.png" class="close" />
				</a>
				<h1 class="mui-title">登录/注册</h1>
			</header>
			<div>
				<div class="login-bottom-wrap div-tab" style="">
					<div class="phone input-wrap input1">
						<span>手机：</span>
						<input type="text" id="phone" data-type="tel" field="mobile" required="true" errmsg="请输入正确的手机号码" style="width: 65%; margin-bottom: 0;" placeholder="请输入您的手机号码">
					</div>
					<div class="phone input-wrap">
						<span>密码：</span>
						<input type="text" id="phone" field="pwd" required="true" errmsg="请输入密码" style="width: 65%; margin-bottom: 0;" placeholder="请输入登录密码">
						<!--<div id="getcode">获取验证码</div>-->
					</div>
					<p class="go-login login"> <span class="yzmlogin">验证码登录</span><span class="forget">忘记密码</span></p>
					<button class="res-q" id="go-login">登录</button>
					<p class="sm">龙采头条软件负责声明<span class="check is-check"></span></p>
				</div>
			</div>
		</div>
	</body>
</html>
{% include 'front/foot.html' %}
<script>
	defineClass('init', {
		init: function() {
			var it = this;
			it.login();
			$('.yzmlogin').click(function(){
				window.location.href = "/home/register";
			})
			it.params = util.GetRequest(); //获取传参
		},
		login:function(){
			var it = this;
			$('#go-login').click(function(){
				var data = util.getFormCode({
					el: ".login-bottom-wrap"
				});
				if(it.params.be_invite){
					data['be_invite'] = it.params.be_invite
				}
				if(data){
					util.doAjax({
						url:"/api/user/login",
						method:"post",
						data:data,
						success:function(res){
							console.log(res);
						}
					})
				}
				console.log(data);
			})
		}
	})
</script>